Use the ExtensionRegistry instead of checking for the main class
name of the Cite extension. - I'm not entirely sure if this is much
better. A hook would still be the better option. But at least Cite
could be refactored and the class name changed.
Bug: T89151
Change-Id: I35e5aa9955141b575de68a5be2c0d5b87585eb77
3 => "/(\n\\{\\|)|(\n\\|\\})/" ]; // table
// @todo FIXME: This should prolly be a hook or something
- // instead of hardcoding a class name from the Cite extension
- if ( class_exists( 'Cite' ) ) {
+ // instead of hardcoding the name of the Cite extension
+ if ( \ExtensionRegistry::getInstance()->isLoaded( 'Cite' ) ) {
$spat .= '|(<ref>)'; // references via cite extension
$endPatterns[4] = '/(<ref>)|(<\/ref>)/';
}